import { LiftStatusList } from '@/store/constant'
import { PerformanceItem } from '@/types/common'
const LiftStatusChip = ({ row }: { row: PerformanceItem }) => {
  const { is_down, is_up } = row
  const { color, label, icon: ChipIcon } = LiftStatusList.at(findIndex([is_down, is_up], (v: number) => v === 1))!!
  return (
    <Tooltip title={label}>
      <Avatar sx={{ bgcolor: color[50], width: 32, height: 32 }}>
        <ChipIcon color={color[700]} size="1.25rem" />
      </Avatar>
    </Tooltip>
  )
}

export default LiftStatusChip
